Above program is an example of Dynamic Open SQL used within a
sub-routine. In a complex program which requires WHERE statement construction
throughout the codes, the program will append dynamically various information
into “STRWHERE” and “STRLINE”.
As a part of another
sub-routines and codes, this program will generate output dynamically based on
what button the user click. In this example, if the user click “All
Class” the program will display all booking list while if the user click “Business
Class” the program will only display all booking in Business class.
The ability of Dynamic Open SQL is far more than just what explained
in this paper, however using these simple examples we understand that there is
always way to develop our current programming method or system.